package tvs;

//import java.net.InetAddress;

public class Player {
	private String ipaddress;
	private String username;
	private String playername;
	private String email;
	private int win;
	private int loss;
	/*
	public Player(String ip, String name)
	{
		this.ipaddress = ip;
		this.username = name;
		this.win = 0;
		this.loss = 0;
	}
	*/
	
	public Player(String name)
	{
		this.username = name;
	}
	
	public Player(String ip, String name, int win, int loss)
	{
		this.ipaddress = ip;
		this.username = name;
		this.win = win;
		this.loss = loss;
		this.playername = "";
		this.email = "";
	}
	
	public Player(String ip, String name, int win, int loss, String playername, String email)
	{
		this.ipaddress = ip;
		this.username = name;
		this.win = win;
		this.loss = loss;
		this.playername = playername;
		this.email = email;
	}
	
	public String getName()
	{
		return this.username;
	}
	
	public String getIP()
	{
		return this.ipaddress;
	}
	
	public int getWins()
	{
		return this.win;
	}
	public int getLosses()
	{
		return this.loss;
	}
	
	public long getRatio()
	{
		if(this.loss != 0)
			return win/loss;
		else
			return win;
	}
	
	public String getPlayerName()
	{
		return this.playername;
	}
	
	public String getEmail()
	{
		return this.email;
	}
}
